//spu数据的ts类型
export interface SpuData {
  id?: number | string; //SPU对象的ID
  spuName: string;
  description: string;
  category3Id: number | string;
  tmId: number | string; //品牌ID
  spuSaleAttrList: [];
  spuImageList: [];
}
//商品图片的ts类型
export interface SpuImage {
  id?: string | number;
  spuId?: string | number;
  imgName?: string;
  imgUrl?: string;
  name?: string;
  url?: string;
}
//某一SPU下已有的销售属性值数组ts类型
export interface SaleAttrValue {
  id?: number | string;
  spuId?: number | string;
  baseSaleAttrId: number | string;
  saleAttrName: string;
  spuSaleAttrValueList: SaleValueList[];
  flag?: boolean; //用于控制input|button显示与隐藏
  saleAttrValue?: string; //收集销售属性值名字
  saleIdAndValueId?: string; //收集属性与属性值的ID
}
//某一SPU下已有的销售属性值对象ts类型
export interface SaleValueList {
  id?: number | string;
  spuId?: number | string;
  baseSaleAttrId: number | string;
  isChecked?: string;
  saleAttrName?: string;
  saleAttrValueName: string;
}
//全部销售属性【颜色 版本 尺码】
export interface AllSaleAttr {
  id: number | string;
  name: string;
}

//SKUts数据类型
export interface SkuData {
  id?: string | number;
  category3Id: string | number; //三级分类的ID
  spuId: string | number; //己有的SPU的ID
  tmId: string | number; //SPU品牌的ID
  skuName: string; //sku名字
  price: string | number; //sku价格
  weight: string | number; //sku重量
  skuDesc: string; //sku的描述
  skuAttrValueList: skuAttrValue[]; //平台属性的收集
  skuSaleAttrValueList: skuSaleAttrValue[]; //销售属性
  skuDefaultImg: string; //sku图片地址
  isSale?: string | number; //用于判断商品上架｜下架 1:上海；0:下架
  skuImageList?: SpuImage[];
}
//SKU 平台属性值的ts类型
export interface skuAttrValue {
  id?: number | string;
  attrId: number | string;
  valueId: number | string;
  valueName?: string;
}
//SKU 销售属性值的ts类型
export interface skuSaleAttrValue {
  id?: number | string;
  saleAttrId: number | string;
  saleAttrValueId: number | string;
  saleAttrName?: string;
}
